package com.zjcloud.jwgl.domain;

import java.math.BigDecimal;
import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.zjcloud.common.annotation.Excel;
import com.zjcloud.common.core.domain.BaseEntity;

/**
 * 算法配置历史对象 ac_algorithm_config_history
 * 
 * @author zjcloud
 * @date 2024-12-19
 */
public class AcAlgorithmConfigHistory extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 历史记录ID */
    private Long id;

    /** 配置ID */
    @Excel(name = "配置ID")
    private Long configId;

    /** 操作类型(CREATE创建 UPDATE更新 DELETE删除 COPY复制) */
    @Excel(name = "操作类型", readConverterExp = "CREATE=创建,UPDATE=更新,DELETE=删除,COPY=复制")
    private String operationType;

    /** 变更前配置JSON */
    private String beforeConfig;

    /** 变更后配置JSON */
    private String afterConfig;

    /** 变更字段列表 */
    @Excel(name = "变更字段列表")
    private String changedFields;

    /** 变更原因 */
    @Excel(name = "变更原因")
    private String changeReason;

    /** 操作人ID */
    @Excel(name = "操作人ID")
    private Long operatorId;

    /** 操作人姓名 */
    @Excel(name = "操作人姓名")
    private String operatorName;

    /** 操作时间 */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @Excel(name = "操作时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
    private Date operationTime;

    /** IP地址 */
    @Excel(name = "IP地址")
    private String ipAddress;

    /** 用户代理 */
    @Excel(name = "用户代理")
    private String userAgent;

    /** 配置版本 */
    @Excel(name = "配置版本")
    private String configVersion;

    /** 是否回滚(1是 0否) */
    @Excel(name = "是否回滚", readConverterExp = "0=否,1=是")
    private Integer isRollback;

    /** 回滚目标版本 */
    @Excel(name = "回滚目标版本")
    private String rollbackTargetVersion;

    /** 算法配置信息 */
    private AcScheduleAlgorithmConfig algorithmConfig;

    public void setId(Long id) 
    {
        this.id = id;
    }

    public Long getId() 
    {
        return id;
    }
    public void setConfigId(Long configId) 
    {
        this.configId = configId;
    }

    public Long getConfigId() 
    {
        return configId;
    }
    public void setOperationType(String operationType) 
    {
        this.operationType = operationType;
    }

    public String getOperationType() 
    {
        return operationType;
    }
    public void setBeforeConfig(String beforeConfig) 
    {
        this.beforeConfig = beforeConfig;
    }

    public String getBeforeConfig() 
    {
        return beforeConfig;
    }
    public void setAfterConfig(String afterConfig) 
    {
        this.afterConfig = afterConfig;
    }

    public String getAfterConfig() 
    {
        return afterConfig;
    }
    public void setChangedFields(String changedFields) 
    {
        this.changedFields = changedFields;
    }

    public String getChangedFields() 
    {
        return changedFields;
    }
    public void setChangeReason(String changeReason) 
    {
        this.changeReason = changeReason;
    }

    public String getChangeReason() 
    {
        return changeReason;
    }
    public void setOperatorId(Long operatorId) 
    {
        this.operatorId = operatorId;
    }

    public Long getOperatorId() 
    {
        return operatorId;
    }
    public void setOperatorName(String operatorName) 
    {
        this.operatorName = operatorName;
    }

    public String getOperatorName() 
    {
        return operatorName;
    }
    public void setOperationTime(Date operationTime) 
    {
        this.operationTime = operationTime;
    }

    public Date getOperationTime() 
    {
        return operationTime;
    }
    public void setIpAddress(String ipAddress) 
    {
        this.ipAddress = ipAddress;
    }

    public String getIpAddress() 
    {
        return ipAddress;
    }
    public void setUserAgent(String userAgent) 
    {
        this.userAgent = userAgent;
    }

    public String getUserAgent() 
    {
        return userAgent;
    }
    public void setConfigVersion(String configVersion) 
    {
        this.configVersion = configVersion;
    }

    public String getConfigVersion() 
    {
        return configVersion;
    }
    public void setIsRollback(Integer isRollback) 
    {
        this.isRollback = isRollback;
    }

    public Integer getIsRollback() 
    {
        return isRollback;
    }
    public void setRollbackTargetVersion(String rollbackTargetVersion) 
    {
        this.rollbackTargetVersion = rollbackTargetVersion;
    }

    public String getRollbackTargetVersion() 
    {
        return rollbackTargetVersion;
    }
    public void setAlgorithmConfig(AcScheduleAlgorithmConfig algorithmConfig) 
    {
        this.algorithmConfig = algorithmConfig;
    }

    public AcScheduleAlgorithmConfig getAlgorithmConfig() 
    {
        return algorithmConfig;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("id", getId())
            .append("configId", getConfigId())
            .append("operationType", getOperationType())
            .append("beforeConfig", getBeforeConfig())
            .append("afterConfig", getAfterConfig())
            .append("changedFields", getChangedFields())
            .append("changeReason", getChangeReason())
            .append("operatorId", getOperatorId())
            .append("operatorName", getOperatorName())
            .append("operationTime", getOperationTime())
            .append("ipAddress", getIpAddress())
            .append("userAgent", getUserAgent())
            .append("configVersion", getConfigVersion())
            .append("isRollback", getIsRollback())
            .append("rollbackTargetVersion", getRollbackTargetVersion())
            .append("createBy", getCreateBy())
            .append("createTime", getCreateTime())
            .append("updateBy", getUpdateBy())
            .append("updateTime", getUpdateTime())
            .append("remark", getRemark())
            .toString();
    }
}